import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileReader;
import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

public class Main {
    private static Scanner cin = null;

    static {
        try {
            cin = new Scanner(new FileReader(new File("E.in")));
        } catch (FileNotFoundException e) {
            cin = new Scanner(System.in);
        }
    }

    //Ctrl+Alt+L
    //Ctrl+D  ^D EOF
    public static void main(String[] args) {
        final String regex = "\\d+";
        while (cin.hasNextLine()) {
            String line = cin.nextLine();
            // 创建 Pattern 对象
            Pattern r = Pattern.compile(regex);
            // 现在创建 matcher 对象
            int count = 0;
            List<String> numbers = new ArrayList<>();
            Matcher m = r.matcher(line);
            while (m.find()) {
                ++count;
                numbers.add(m.group());
            }
            System.out.println(count);
            for (String number : numbers) {
                System.out.println(number);
            }
        }

    }
}